﻿namespace WeWork.Model
{
    /// <summary>
    /// 互通红包消息
    /// </summary>
    public class ChatExternalRedPacket : MsgChatRoomBase
    {
        /*
        {
            "msgid":"8632214264349267353_1603786184",
            "action":"send",
            "from":"woJ7ijBwAAmqwojT8r_DaNMbr_NAvaag",
            "tolist":["woJ7ijBwAA6SjS_sIyPLZtyEPJlT7Cfw","tiny-six768"],
            "roomid":"wrJ7ijBwAAG1vly_DzVI72Ghc-PtA5Dw",
            "msgtime":1603786183955,
            "msgtype":"external_redpacket",
            "redpacket":{
                "type":1,
                "wish":"恭喜发财，大吉大利",
                "totalcnt":2,
                "totalamount":20
            }
        }
        */
        /// <summary>
        /// 消息内容
        /// </summary>
        public ExternalRedPacketInfo redpacket { set; get; }
    }

    public class ExternalRedPacketInfo
    {
        /// <summary>
        /// 红包消息类型。1 普通红包、2 拼手气群红包。Uint32类型
        /// </summary>
        public int type { set; get; }
        /// <summary>
        /// 红包祝福语。String类型
        /// </summary>
        public string wish { set; get; }
        /// <summary>
        /// 红包总个数。Uint32类型
        /// </summary>
        public int totalcnt { set; get; }
        /// <summary>
        /// 红包总金额。Uint32类型，单位为分。
        /// </summary>
        public int totalamount { set; get; }
    }
}
